{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "字段说明\n",
    "  Pregnancies: 怀孕次数\n",
    "  Glucose: 口服葡萄糖耐受试验中,2 小时的血浆葡萄糖浓度。\n",
    "  BloodPressure: 舒张压(mm Hg)\n",
    "  SkinThickness: 三头肌皮肤褶层厚度(mm)\n",
    "  Insulin:2 小时血清胰岛素含量(μU/ ml)\n",
    "  BMI: 体重指数(体重,kg /(身高,m)^ 2)\n",
    "  DiabetesPedigreeFunction: 糖尿病家族史\n",
    "  Age: 年龄(岁)\n",
    "  \n",
    "  Outcome: 输出变了/类别标签(0 或 1,出现糖尿病为 1, 否则为 0)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 40,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Pregnancies</th>\n",
       "      <th>Glucose</th>\n",
       "      <th>BloodPressure</th>\n",
       "      <th>SkinThickness</th>\n",
       "      <th>Insulin</th>\n",
       "      <th>BMI</th>\n",
       "      <th>DiabetesPedigreeFunction</th>\n",
       "      <th>Age</th>\n",
       "      <th>Outcome</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>6</td>\n",
       "      <td>148</td>\n",
       "      <td>72</td>\n",
       "      <td>35</td>\n",
       "      <td>0</td>\n",
       "      <td>33.6</td>\n",
       "      <td>0.627</td>\n",
       "      <td>50</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>1</td>\n",
       "      <td>85</td>\n",
       "      <td>66</td>\n",
       "      <td>29</td>\n",
       "      <td>0</td>\n",
       "      <td>26.6</td>\n",
       "      <td>0.351</td>\n",
       "      <td>31</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>8</td>\n",
       "      <td>183</td>\n",
       "      <td>64</td>\n",
       "      <td>0</td>\n",
       "      <td>0</td>\n",
       "      <td>23.3</td>\n",
       "      <td>0.672</td>\n",
       "      <td>32</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>1</td>\n",
       "      <td>89</td>\n",
       "      <td>66</td>\n",
       "      <td>23</td>\n",
       "      <td>94</td>\n",
       "      <td>28.1</td>\n",
       "      <td>0.167</td>\n",
       "      <td>21</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>0</td>\n",
       "      <td>137</td>\n",
       "      <td>40</td>\n",
       "      <td>35</td>\n",
       "      <td>168</td>\n",
       "      <td>43.1</td>\n",
       "      <td>2.288</td>\n",
       "      <td>33</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "   Pregnancies  Glucose  BloodPressure  SkinThickness  Insulin   BMI  \\\n",
       "0            6      148             72             35        0  33.6   \n",
       "1            1       85             66             29        0  26.6   \n",
       "2            8      183             64              0        0  23.3   \n",
       "3            1       89             66             23       94  28.1   \n",
       "4            0      137             40             35      168  43.1   \n",
       "\n",
       "   DiabetesPedigreeFunction  Age  Outcome  \n",
       "0                     0.627   50        1  \n",
       "1                     0.351   31        0  \n",
       "2                     0.672   32        1  \n",
       "3                     0.167   21        0  \n",
       "4                     2.288   33        1  "
      ]
     },
     "execution_count": 40,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandas as pd \n",
    "import numpy as np\n",
    " \n",
    "from sklearn.model_selection import GridSearchCV\n",
    " \n",
    "#竞赛的评价指标为logloss\n",
    "#from sklearn.metrics import log_loss  \n",
    "#SVM并不能直接输出各类的概率，所以在这个例子中我们用正确率作为模型预测性能的度量\n",
    "from sklearn.metrics import accuracy_score\n",
    " \n",
    "from matplotlib import pyplot\n",
    "import seaborn as sns\n",
    "%matplotlib inline\n",
    "\n",
    "data = pd.read_csv('diabetes.csv')\n",
    "data.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 41,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "(768, 9)"
      ]
     },
     "execution_count": 41,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data.shape"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 42,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Pregnancies</th>\n",
       "      <th>Glucose</th>\n",
       "      <th>BloodPressure</th>\n",
       "      <th>SkinThickness</th>\n",
       "      <th>Insulin</th>\n",
       "      <th>BMI</th>\n",
       "      <th>DiabetesPedigreeFunction</th>\n",
       "      <th>Age</th>\n",
       "      <th>Outcome</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>count</th>\n",
       "      <td>768.000000</td>\n",
       "      <td>768.000000</td>\n",
       "      <td>768.000000</td>\n",
       "      <td>768.000000</td>\n",
       "      <td>768.000000</td>\n",
       "      <td>768.000000</td>\n",
       "      <td>768.000000</td>\n",
       "      <td>768.000000</td>\n",
       "      <td>768.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>mean</th>\n",
       "      <td>3.845052</td>\n",
       "      <td>120.894531</td>\n",
       "      <td>69.105469</td>\n",
       "      <td>20.536458</td>\n",
       "      <td>79.799479</td>\n",
       "      <td>31.992578</td>\n",
       "      <td>0.471876</td>\n",
       "      <td>33.240885</td>\n",
       "      <td>0.348958</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>std</th>\n",
       "      <td>3.369578</td>\n",
       "      <td>31.972618</td>\n",
       "      <td>19.355807</td>\n",
       "      <td>15.952218</td>\n",
       "      <td>115.244002</td>\n",
       "      <td>7.884160</td>\n",
       "      <td>0.331329</td>\n",
       "      <td>11.760232</td>\n",
       "      <td>0.476951</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>min</th>\n",
       "      <td>0.000000</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>0.078000</td>\n",
       "      <td>21.000000</td>\n",
       "      <td>0.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25%</th>\n",
       "      <td>1.000000</td>\n",
       "      <td>99.000000</td>\n",
       "      <td>62.000000</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>27.300000</td>\n",
       "      <td>0.243750</td>\n",
       "      <td>24.000000</td>\n",
       "      <td>0.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>50%</th>\n",
       "      <td>3.000000</td>\n",
       "      <td>117.000000</td>\n",
       "      <td>72.000000</td>\n",
       "      <td>23.000000</td>\n",
       "      <td>30.500000</td>\n",
       "      <td>32.000000</td>\n",
       "      <td>0.372500</td>\n",
       "      <td>29.000000</td>\n",
       "      <td>0.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>75%</th>\n",
       "      <td>6.000000</td>\n",
       "      <td>140.250000</td>\n",
       "      <td>80.000000</td>\n",
       "      <td>32.000000</td>\n",
       "      <td>127.250000</td>\n",
       "      <td>36.600000</td>\n",
       "      <td>0.626250</td>\n",
       "      <td>41.000000</td>\n",
       "      <td>1.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>max</th>\n",
       "      <td>17.000000</td>\n",
       "      <td>199.000000</td>\n",
       "      <td>122.000000</td>\n",
       "      <td>99.000000</td>\n",
       "      <td>846.000000</td>\n",
       "      <td>67.100000</td>\n",
       "      <td>2.420000</td>\n",
       "      <td>81.000000</td>\n",
       "      <td>1.000000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "       Pregnancies     Glucose  BloodPressure  SkinThickness     Insulin  \\\n",
       "count   768.000000  768.000000     768.000000     768.000000  768.000000   \n",
       "mean      3.845052  120.894531      69.105469      20.536458   79.799479   \n",
       "std       3.369578   31.972618      19.355807      15.952218  115.244002   \n",
       "min       0.000000    0.000000       0.000000       0.000000    0.000000   \n",
       "25%       1.000000   99.000000      62.000000       0.000000    0.000000   \n",
       "50%       3.000000  117.000000      72.000000      23.000000   30.500000   \n",
       "75%       6.000000  140.250000      80.000000      32.000000  127.250000   \n",
       "max      17.000000  199.000000     122.000000      99.000000  846.000000   \n",
       "\n",
       "              BMI  DiabetesPedigreeFunction         Age     Outcome  \n",
       "count  768.000000                768.000000  768.000000  768.000000  \n",
       "mean    31.992578                  0.471876   33.240885    0.348958  \n",
       "std      7.884160                  0.331329   11.760232    0.476951  \n",
       "min      0.000000                  0.078000   21.000000    0.000000  \n",
       "25%     27.300000                  0.243750   24.000000    0.000000  \n",
       "50%     32.000000                  0.372500   29.000000    0.000000  \n",
       "75%     36.600000                  0.626250   41.000000    1.000000  \n",
       "max     67.100000                  2.420000   81.000000    1.000000  "
      ]
     },
     "execution_count": 42,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data.describe()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 43,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<class 'pandas.core.frame.DataFrame'>\n",
      "RangeIndex: 768 entries, 0 to 767\n",
      "Data columns (total 9 columns):\n",
      "Pregnancies                 768 non-null int64\n",
      "Glucose                     768 non-null int64\n",
      "BloodPressure               768 non-null int64\n",
      "SkinThickness               768 non-null int64\n",
      "Insulin                     768 non-null int64\n",
      "BMI                         768 non-null float64\n",
      "DiabetesPedigreeFunction    768 non-null float64\n",
      "Age                         768 non-null int64\n",
      "Outcome                     768 non-null int64\n",
      "dtypes: float64(2), int64(7)\n",
      "memory usage: 54.1 KB\n"
     ]
    }
   ],
   "source": [
    "data.info()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 44,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "Pregnancies                 0\n",
       "Glucose                     0\n",
       "BloodPressure               0\n",
       "SkinThickness               0\n",
       "Insulin                     0\n",
       "BMI                         0\n",
       "DiabetesPedigreeFunction    0\n",
       "Age                         0\n",
       "Outcome                     0\n",
       "dtype: int64"
      ]
     },
     "execution_count": 44,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "data.isnull().sum()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 45,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYgAAAEKCAYAAAAIO8L1AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMi4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvIxREBQAAEl1JREFUeJzt3X/wZXV93/HnC9D4M6KwUrrLurSurWaMaLcOGTLVYOL4owElIaO1YSXbbGZCWxoyqWipJLWZaCMSHDIk22JdqBE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f5BkV5JNs65pJfFOaklSl0cQkqQuA0KS1GVASJK6DAhJUpcBIUnqMiC04iVZk+TKJLcm+XKSC9o9IYt95m3LVZ80KwaEVrQkAT4MfKSq1gPPA54G/OYSHzUgdNAzILTSnQg8UFX/FaCqvg/8CvALSX45yYULHZN8LMnLk7wTeHKSLyT5QNt2WpIbk9yQ5NLW9pwk21r7tiRrW/v7k1yU5BNJbkvysvbcg1uSvH/q+16Z5C+TfC7JHyZ52rL9V5EwIKQfAa6fbqiq+4Db2ccz26vqbOBvquq4qnpTkh8B/h1wYlW9CDizdb0QuKSqfhT4APDeqd08k0k4/QrwUeD8VssLkxyX5EjgHOAnq+olwHbgrMfiB0tDdf8HkFaQ0J+9dl/tPScCV1TV1wCqauH5BT8GnNKWLwX+09RnPlpVlWQHcFdV7QBIcjOwjsmkiS8A/mJyFownMplyQlo2BoRWupuBn5luSPLDTGa4vZeHH2U/aR/7GBom032+294fmlpeWD8M+D5wTVW9ccB+pVF4ikkr3TbgKUlOg799BOt5TB51eRtwXJJDkhzD5Ol7C/5fkidM7ePnkhzR9vGs1v4pJrPjArwJ+PNHUdd1wAlJntv2+ZQkz3u0P046EAaEVrSazFb5euDUJLcCfw08wOQqpb8A/jewA3g38Lmpj24BbkzygTb77W8Cn0xyA/Ce1udfA6cnuRH4eX4wNjGkrj3Am4EPts9fB/zD/f2d0v5wNldJUpdHEJKkLgNCktRlQEiSugwISVKXASFJ6jIgJEldBoQkqcuAkCR1/X9K6pHz/1wAcgAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "#看看各类样本分布数量\n",
    "sns.countplot(data.Outcome)\n",
    "pyplot.xlabel('Outcome');\n",
    "pyplot.ylabel('Number of type');"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 46,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/home/peng/anaconda3/lib/python3.7/site-packages/sklearn/model_selection/_split.py:2026: FutureWarning: From version 0.21, test_size will always complement train_size unless both are specified.\n",
      "  FutureWarning)\n"
     ]
    }
   ],
   "source": [
    "y_train = data.Outcome\n",
    "X_train = data.drop('Outcome',axis=1)\n",
    "\n",
    "# 数据标准化\n",
    "from sklearn.preprocessing import StandardScaler\n",
    " \n",
    "# 初始化特征的标准化器\n",
    "ss_X = StandardScaler()\n",
    "X_train = ss_X.fit_transform(X_train)\n",
    "\n",
    "from sklearn.model_selection import train_test_split\n",
    "X_train_part, X_val, y_train_part, y_val = train_test_split(X_train, y_train, train_size = 0.8,random_state = 33)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Logistic 回归最优参数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 47,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/home/peng/anaconda3/lib/python3.7/site-packages/sklearn/utils/deprecation.py:122: FutureWarning: You are accessing a training score ('split0_train_score'), which will not be available by default any more in 0.21. If you need training scores, please set return_train_score=True\n",
      "  warnings.warn(*warn_args, **warn_kwargs)\n",
      "/home/peng/anaconda3/lib/python3.7/site-packages/sklearn/utils/deprecation.py:122: FutureWarning: You are accessing a training score ('split1_train_score'), which will not be available by default any more in 0.21. If you need training scores, please set return_train_score=True\n",
      "  warnings.warn(*warn_args, **warn_kwargs)\n",
      "/home/peng/anaconda3/lib/python3.7/site-packages/sklearn/utils/deprecation.py:122: FutureWarning: You are accessing a training score ('split2_train_score'), which will not be available by default any more in 0.21. If you need training scores, please set return_train_score=True\n",
      "  warnings.warn(*warn_args, **warn_kwargs)\n",
      "/home/peng/anaconda3/lib/python3.7/site-packages/sklearn/utils/deprecation.py:122: FutureWarning: You are accessing a training score ('split3_train_score'), which will not be available by default any more in 0.21. If you need training scores, please set return_train_score=True\n",
      "  warnings.warn(*warn_args, **warn_kwargs)\n",
      "/home/peng/anaconda3/lib/python3.7/site-packages/sklearn/utils/deprecation.py:122: FutureWarning: You are accessing a training score ('split4_train_score'), which will not be available by default any more in 0.21. If you need training scores, please set return_train_score=True\n",
      "  warnings.warn(*warn_args, **warn_kwargs)\n",
      "/home/peng/anaconda3/lib/python3.7/site-packages/sklearn/utils/deprecation.py:122: FutureWarning: You are accessing a training score ('mean_train_score'), which will not be available by default any more in 0.21. If you need training scores, please set return_train_score=True\n",
      "  warnings.warn(*warn_args, **warn_kwargs)\n",
      "/home/peng/anaconda3/lib/python3.7/site-packages/sklearn/utils/deprecation.py:122: FutureWarning: You are accessing a training score ('std_train_score'), which will not be available by default any more in 0.21. If you need training scores, please set return_train_score=True\n",
      "  warnings.warn(*warn_args, **warn_kwargs)\n"
     ]
    },
    {
     "data": {
      "text/plain": [
       "{'mean_fit_time': array([0.00155559, 0.00185828, 0.00142202, 0.00199757, 0.00222163,\n",
       "        0.00213466, 0.002174  , 0.00213585, 0.00225134, 0.00219903,\n",
       "        0.00225139, 0.00212765, 0.00228958, 0.00210013]),\n",
       " 'std_fit_time': array([2.91012690e-04, 4.10000660e-05, 3.31069244e-05, 1.68468302e-04,\n",
       "        1.58749138e-04, 7.11363054e-05, 5.94007055e-05, 5.81638921e-05,\n",
       "        6.32857227e-05, 1.40210283e-04, 1.84379001e-04, 8.71057637e-05,\n",
       "        4.82526220e-05, 4.73618612e-05]),\n",
       " 'mean_score_time': array([0.00142899, 0.00121031, 0.0012207 , 0.00129919, 0.00131459,\n",
       "        0.00122819, 0.00130763, 0.00122056, 0.00125952, 0.00123873,\n",
       "        0.00121965, 0.00121107, 0.00132394, 0.0012332 ]),\n",
       " 'std_score_time': array([2.57739796e-04, 1.61468356e-05, 3.93143490e-05, 1.30877199e-04,\n",
       "        8.35825492e-05, 2.03635708e-05, 1.97969362e-04, 2.86957733e-05,\n",
       "        1.16065279e-04, 4.81937313e-05, 3.03467050e-05, 2.45414147e-05,\n",
       "        1.68679755e-04, 5.98084969e-05]),\n",
       " 'param_C': masked_array(data=[0.001, 0.001, 0.01, 0.01, 0.1, 0.1, 1, 1, 10, 10, 100,\n",
       "                    100, 1000, 1000],\n",
       "              mask=[False, False, False, False, False, False, False, False,\n",
       "                    False, False, False, False, False, False],\n",
       "        fill_value='?',\n",
       "             dtype=object),\n",
       " 'param_penalty': masked_array(data=['l1', 'l2', 'l1', 'l2', 'l1', 'l2', 'l1', 'l2', 'l1',\n",
       "                    'l2', 'l1', 'l2', 'l1', 'l2'],\n",
       "              mask=[False, False, False, False, False, False, False, False,\n",
       "                    False, False, False, False, False, False],\n",
       "        fill_value='?',\n",
       "             dtype=object),\n",
       " 'params': [{'C': 0.001, 'penalty': 'l1'},\n",
       "  {'C': 0.001, 'penalty': 'l2'},\n",
       "  {'C': 0.01, 'penalty': 'l1'},\n",
       "  {'C': 0.01, 'penalty': 'l2'},\n",
       "  {'C': 0.1, 'penalty': 'l1'},\n",
       "  {'C': 0.1, 'penalty': 'l2'},\n",
       "  {'C': 1, 'penalty': 'l1'},\n",
       "  {'C': 1, 'penalty': 'l2'},\n",
       "  {'C': 10, 'penalty': 'l1'},\n",
       "  {'C': 10, 'penalty': 'l2'},\n",
       "  {'C': 100, 'penalty': 'l1'},\n",
       "  {'C': 100, 'penalty': 'l2'},\n",
       "  {'C': 1000, 'penalty': 'l1'},\n",
       "  {'C': 1000, 'penalty': 'l2'}],\n",
       " 'split0_test_score': array([-0.69314718, -0.63247716, -0.64643499, -0.51842729, -0.49335267,\n",
       "        -0.4893871 , -0.49423608, -0.49442383, -0.4955052 , -0.49553449,\n",
       "        -0.49565018, -0.49565533, -0.49566214, -0.49566752]),\n",
       " 'split1_test_score': array([-0.69314718, -0.64153853, -0.65138433, -0.54263843, -0.51621738,\n",
       "        -0.50836483, -0.50929683, -0.50834194, -0.5087495 , -0.50865995,\n",
       "        -0.50869859, -0.5086969 , -0.50870696, -0.50870065]),\n",
       " 'split2_test_score': array([-0.69314718, -0.63662203, -0.64570415, -0.52403018, -0.47822781,\n",
       "        -0.48374951, -0.48180059, -0.4830274 , -0.48313807, -0.48326216,\n",
       "        -0.4832739 , -0.48329051, -0.48329388, -0.4832934 ]),\n",
       " 'split3_test_score': array([-0.69314718, -0.63189062, -0.64433664, -0.50307754, -0.45405668,\n",
       "        -0.44275292, -0.43662157, -0.43615578, -0.43568832, -0.43565059,\n",
       "        -0.43560697, -0.43560284, -0.43559766, -0.43559809]),\n",
       " 'split4_test_score': array([-0.69314718, -0.64067605, -0.64757466, -0.53287257, -0.49692035,\n",
       "        -0.48956528, -0.48810134, -0.48793522, -0.48808502, -0.48807935,\n",
       "        -0.48809951, -0.48809877, -0.48810046, -0.48810077]),\n",
       " 'mean_test_score': array([-0.69314718, -0.63664181, -0.6470899 , -0.52422544, -0.48778692,\n",
       "        -0.48280717, -0.48206246, -0.48202874, -0.48228621, -0.48229036,\n",
       "        -0.48231899, -0.48232204, -0.48232541, -0.48232527]),\n",
       " 'std_test_score': array([1.11022302e-16, 4.00318135e-03, 2.39292199e-03, 1.33688676e-02,\n",
       "        2.07337741e-02, 2.16460757e-02, 2.44353358e-02, 2.44134571e-02,\n",
       "        2.47968928e-02, 2.47956827e-02, 2.48337102e-02, 2.48355509e-02,\n",
       "        2.48404689e-02, 2.48395553e-02]),\n",
       " 'rank_test_score': array([14, 12, 13, 11, 10,  9,  2,  1,  3,  4,  5,  6,  8,  7],\n",
       "       dtype=int32),\n",
       " 'split0_train_score': array([-0.69314718, -0.63735556, -0.64699594, -0.5192309 , -0.47577629,\n",
       "        -0.46925194, -0.46602434, -0.46594583, -0.46589353, -0.46589258,\n",
       "        -0.46589202, -0.46589201, -0.46589201, -0.46589201]),\n",
       " 'split1_train_score': array([-0.69314718, -0.63310132, -0.63649244, -0.51411049, -0.47224558,\n",
       "        -0.46704903, -0.46420472, -0.46410775, -0.4640626 , -0.4640616 ,\n",
       "        -0.46406112, -0.46406111, -0.4640611 , -0.4640611 ]),\n",
       " 'split2_train_score': array([-0.69314718, -0.6356616 , -0.65056852, -0.51951737, -0.47886777,\n",
       "        -0.47222043, -0.46932984, -0.46925675, -0.46921156, -0.46921058,\n",
       "        -0.4692101 , -0.46921009, -0.46921008, -0.46921008]),\n",
       " 'split3_train_score': array([-0.69314718, -0.63804443, -0.65182756, -0.52743851, -0.48993925,\n",
       "        -0.48357524, -0.48097739, -0.48088442, -0.4808438 , -0.48084284,\n",
       "        -0.48084241, -0.4808424 , -0.48084239, -0.48084239]),\n",
       " 'split4_train_score': array([-0.69314718, -0.63358836, -0.646171  , -0.51771935, -0.4775953 ,\n",
       "        -0.47164861, -0.46882388, -0.46875047, -0.46870586, -0.46870513,\n",
       "        -0.46870465, -0.46870464, -0.46870464, -0.46870464]),\n",
       " 'mean_train_score': array([-0.69314718, -0.63555025, -0.64641109, -0.51960333, -0.47888484,\n",
       "        -0.47274905, -0.46987203, -0.46978904, -0.46974347, -0.46974255,\n",
       "        -0.46974206, -0.46974205, -0.46974205, -0.46974205]),\n",
       " 'std_train_score': array([0.        , 0.00196666, 0.00539262, 0.00436479, 0.00595997,\n",
       "        0.00571694, 0.00585909, 0.0058569 , 0.00585954, 0.00585954,\n",
       "        0.00585957, 0.00585957, 0.00585957, 0.00585957])}"
      ]
     },
     "execution_count": 47,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "\n",
    "from sklearn.model_selection import GridSearchCV\n",
    "from sklearn.linear_model import LogisticRegression\n",
    "\n",
    "penaltys = ['l1','l2']\n",
    "Cs = [0.001, 0.01, 0.1, 1, 10, 100, 1000]\n",
    "tuned_parameters = dict(penalty = penaltys, C = Cs)\n",
    " \n",
    "lr_penalty= LogisticRegression()\n",
    "grid= GridSearchCV(lr_penalty, tuned_parameters,cv=5, scoring='neg_log_loss')\n",
    "grid.fit(X_train,y_train)\n",
    " \n",
    "grid.cv_results_"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 48,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "0.4820287373783356\n",
      "{'C': 1, 'penalty': 'l2'}\n"
     ]
    }
   ],
   "source": [
    "print(-grid.best_score_)\n",
    "print(grid.best_params_)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 线性SVM最佳参数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 54,
   "metadata": {},
   "outputs": [],
   "source": [
    "def fit_grid_point_Linear(C, X_train, y_train, X_val, y_val):\n",
    "    \n",
    "    # 在训练集是那个利用SVC训练\n",
    "    SVC2 =  LinearSVC( C = C)\n",
    "    SVC2 = SVC2.fit(X_train, y_train)\n",
    "    \n",
    "    # 在校验集上返回accuracy\n",
    "    accuracy = SVC2.score(X_val, y_val)\n",
    "    \n",
    "    print(\"accuracy: {}\".format(accuracy))\n",
    "    return accuracy"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 60,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "accuracy: 0.7207792207792207\n",
      "accuracy: 0.7532467532467533\n",
      "accuracy: 0.7467532467532467\n",
      "accuracy: 0.7532467532467533\n",
      "accuracy: 0.7532467532467533\n",
      "accuracy: 0.7532467532467533\n",
      "accuracy: 0.7532467532467533\n",
      "accuracy: 0.7012987012987013\n",
      "accuracy: 0.6623376623376623\n",
      "accuracy: 0.6493506493506493\n"
     ]
    }
   ],
   "source": [
    "C_s = np.logspace(-3, 3, 10) \n",
    "accuracy_s = []\n",
    "for i, oneC in enumerate(C_s):\n",
    "    tmp = fit_grid_point_Linear(oneC, X_train, y_train, X_val, y_val)\n",
    "    accuracy_s.append(tmp)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 61,
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYsAAAEKCAYAAADjDHn2AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDI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ih40PgAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "x_axis = np.log10(C_s)\n",
    "pyplot.plot(x_axis, np.array(accuracy_s), 'b-') \n",
    "pyplot.xlabel( 'log(C)' )                                                                                                      \n",
    "pyplot.ylabel( 'accuracy' )\n",
    "pyplot.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "结论：从结果来看线性SVM和logistic线性回归所得的模型最优解都是L2正则和超参数为1，SVM很难处理大数据，因为SVM模型主要是由支持向量决定，而支持向量随着数据量多项式增加。因此相对于SVM，logistic可以很容易运用到大数据当中"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# RBF核的SVM最佳的超参数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 62,
   "metadata": {},
   "outputs": [],
   "source": [
    "from sklearn.svm import SVC\n",
    "def fit_grid_point_RBF(C, gamma, X_train, y_train, X_val, y_val):\n",
    "    \n",
    "    # 在训练集是那个利用SVC训练\n",
    "    SVC3 =  SVC( C = C, kernel='rbf', gamma = gamma)\n",
    "    SVC3 = SVC3.fit(X_train, y_train)\n",
    "    \n",
    "    # 在校验集上返回accuracy\n",
    "    accuracy = SVC3.score(X_val, y_val)\n",
    "    \n",
    "    print(\"accuracy: {}\".format(accuracy))\n",
    "    return accuracy"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 86,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "accuracy: 0.6428571428571429\n",
      "accuracy: 0.6428571428571429\n",
      "accuracy: 0.6428571428571429\n",
      "accuracy: 0.6558441558441559\n",
      "accuracy: 0.6428571428571429\n",
      "accuracy: 0.6428571428571429\n",
      "accuracy: 0.6818181818181818\n",
      "accuracy: 0.7532467532467533\n",
      "accuracy: 0.6428571428571429\n",
      "accuracy: 0.6818181818181818\n",
      "accuracy: 0.7597402597402597\n",
      "accuracy: 0.7662337662337663\n",
      "accuracy: 0.6818181818181818\n",
      "accuracy: 0.7532467532467533\n",
      "accuracy: 0.7597402597402597\n",
      "accuracy: 0.7662337662337663\n",
      "accuracy: 0.7532467532467533\n",
      "accuracy: 0.7597402597402597\n",
      "accuracy: 0.7597402597402597\n",
      "accuracy: 0.7727272727272727\n",
      "accuracy: 0.7532467532467533\n",
      "accuracy: 0.7597402597402597\n",
      "accuracy: 0.7597402597402597\n",
      "accuracy: 0.8051948051948052\n"
     ]
    }
   ],
   "source": [
    "C_s = np.logspace(-1, 4, 6)\n",
    "gamma_s = np.logspace(-5, -2, 4)   \n",
    "\n",
    "accuracy_s = []\n",
    "for i, oneC in enumerate(C_s):\n",
    "    for j, gamma in enumerate(gamma_s):\n",
    "        #print(\"ssss\")\n",
    "        tmp = fit_grid_point_RBF(oneC, gamma, X_train, y_train, X_val, y_val)\n",
    "        accuracy_s.append(tmp)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 88,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYsAAAEKCAYAAADjDHn2AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMi4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvIxREBQAAIABJREFUeJzs3XmczdX/wPHXmX1hFmZsMxj7zmAwlFCJihZfZWmRyhYqSttPEZEsSUhIpIQSUmmZSlQMRkZlH2ObMZh9X+5yfn/cmWlmDLOYez9z7z3Px2Me7vL53M97Fvd9P59z3u8jpJQoiqIoyo04aB2AoiiKUv2pZKEoiqKUSSULRVEUpUwqWSiKoihlUslCURRFKZNKFoqiKEqZVLJQFEVRyqSShaIoilImlSwURVGUMjlpHUBV8fPzk0FBQVqHoSiKYlUOHTqUIKX0L2s7m0kWQUFBREREaB2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fkBcFpV/xqK1/Oyn0WLo6r3+B1DC9CYplQmDIhIFE6iWK2qf/I7nlBS1W9EZAvOuapwXdgwCkgRkUlANHCdiKxS1RlevFhEzSwMUKsplYi0x2lK9d8+x2SamYgIsBzIV9WX/I4nFESku9uWGRHpCNwDHPI3Ku+o6nxV7aWqfXH+jz/0KlGAJYsaIvJjESnAaemaIyIb/Y7JCw01pfI3Km+JSDawHbhNRApE5GG/YwqBUcCDwFgR2et+TfI7KI/1BDaLyH6cD0WbVNXT5aSRxK7gNsYYE5DNLIwxxgRkycIYY0xAliyMMcYEZMnCGGNMQJYsjDHGBGTJwphrICJlgbe66v5viUg/93ZnEXlFRI66VVJzRSRRRNq7tyPqolnTslmyMCZERGQA0FZVv3AfysIpcBivqgOAmUCMW+Dxz0CqL4EaUw9LFsYEQRwZbm2xPBFJdR9vIyL/6c4U1ovIeyIy1d3tAWCtu93NQCKwQFWrAdxKwDnutu+62xvTItg015jgTMHpmZAAxAC7RCQX58rpvsAgIBbnKvkV7j6jgGz39gBgr6peauD5DwB/70nkxgTBZhbGBGc0kO1WOf0K2Irz5j4a+KOqVqtqEbC51j49gTONeXI3iVSISJdmjtuYoFiyMCY49ZV6v9rjABdwqoMCfAokiMjV/gc7AOVBxGZMs7NkYUxwcoFUt9lOd+D7wE5gG/CP7rmLG4G7au2TD9wCoKpHgU+AX7sVYhGR+Mu9VUSkG3BGVStDNSBjrsaShTHBeQfYD+wDPgTmuYed3sbpGXIAeAWnO12pu08OVyaPR4AewOcikgf8F9/2FrkbeM/bIRjTeFZ11phmJiKdVbXMnR3sBEapapHbY2Gze7+hE9uXn+NPwPwI6QtvWgFbDWVM81vvNuFpD/ybO+NAVS+IyLM4Pc9PNLSz25TqXUsUpiWxmYUxxpiA7JyFMcaYgCxZGGOMCciShTHGmIAsWRhjjAnIkoUxxpiALFkYY4wJ6P8BOdA5x+52fR8AAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "accuracy_s1 =np.array(accuracy_s).reshape(len(C_s),len(gamma_s))\n",
    "x_axis = np.log10(C_s)\n",
    "\n",
    "for j, gamma in enumerate(gamma_s):\n",
    "    pyplot.plot(x_axis, np.array(accuracy_s1[:,j]), label = ' Test - log(gamma)' + str(np.log10(gamma)))\n",
    " \n",
    "pyplot.legend()\n",
    "pyplot.xlabel( 'log(C)' )                                                                                                      \n",
    "pyplot.ylabel( 'accuracy' )\n",
    " \n",
    "pyplot.show()"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.0"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
